import React, {Component, PropTypes} from 'react';
import { connect } from 'react-redux';
import { Router, Route, Redirect, IndexRoute, hashHistory } from 'react-router';

import wrapper from '../../wrapper';
import dashboard from '../component/dashboard';


//使用React-Router将组件更好地结合在一起
const RouteConfig = (
    <Router history={hashHistory}>
        <Route component={wrapper} currentPage="dashboard">
            <IndexRoute component={dashboard} />
            <Route  path="/dashboard" component={dashboard} />
        </Route>
        <Redirect from='*' to='/dashboard'  />
    </Router>
);

export default RouteConfig;